package org.red5.audio;

public class AudioSettings {
	
	private int sampleRate, bitRate, channels; 
	
	public AudioSettings() {
		this(44100, 192, 2);
	}
	
	/**
	 * Constructor where one can choose the parameters for the audiosamplerate (in Hz), 
	 * the bitrate (int bits/s) and the number of channels.
	 * 
	 * @param sampleRate in Hz (e.g.: 44100);
	 * @param bitRate bits/s (e.g.: 192);
	 * @param channels number of channels (e.g.: 2);
	 */
	public AudioSettings(int sampleRate, int bitRate, int channels) {
		this.sampleRate = sampleRate;
		this.bitRate = bitRate;
		this.channels = channels;
	}
	
	/**
	 * 
	 * @return returns the samplerate
	 */
	public int getSampleRate() {
		return sampleRate;
	}

	/**
	 * sets the samplerate
	 * 
	 * @param sampleRate
	 */
	public void setSampleRate(int sampleRate) {
		this.sampleRate = sampleRate;
	}

	/**
	 * 
	 * @return returns the bitrate in bits/s
	 */
	public int getBitRate() {
		return bitRate;
	}

	/**
	 * Sets the bitrate in bits/s
	 * 
	 * @param bitRate
	 */
	public void setBitRate(int bitRate) {
		this.bitRate = bitRate;
	}

	/**
	 * 
	 * @return the number of used channels
	 */
	public int getChannels() {
		return channels;
	}

	/**
	 * Sets the number of channels for the mp3
	 * 
	 * @param channels
	 */
	public void setChannels(int channels) {
		this.channels = channels;
	}
}
